//
//  Finger.h
//  ATM Killer
//
//  Created by USoft on 7/16/14.
//
//

#ifndef FINGER_H
#define FINGER_H

#include <iostream>
#include "../entity/FingerInformation.h"
#include "Obj.h"
#include <math.h>

class Finger: public Ref
{
    UG_PROPERTY_FULL(int, level, Level);
    UG_PROPERTY_FULL(int, upgradeLevel, UpgradeLevel);
    UG_PROPERTY_FULL(int, bonusLevel, BonusLevel);
    UG_PROPERTY_FULL(BigNumber*,cost, Cost);
    UG_PROPERTY_FULL(BigNumber*, dpt, Dpt);
    UG_PROPERTY_FULL(int, lastNoti, LastNoti);//upgrade
    UG_PROPERTY_FULL(bool, hasNoti, HasNoti);//upgrade
    UG_PROPERTY_FULL(bool, upgradeAvailable, UpgradeAvailable);//upgrade
    UG_PROPERTY_FULL(int, lastNotiBonus, LastNotiBonus);//bonus
    UG_PROPERTY_FULL(bool, hasNotiBonus, HasNotiBonus);//bonus
    UG_PROPERTY_FULL(bool, bonusAvailable, BonusAvailable);//bonus
    UG_PROPERTY_FULL(float, timeToNextUpgrade, TimeToNextUpgrade);
public:
    CREATE_FUNC(Finger);
    void upLevel(FingerInformation* fingerInformation, int level, int specialLevel, int totalCharactersLevel);
    BigNumber* upgrade(FingerInformation* fingerInformation, int totalLevel, int specialLevel);
private:
    Finger();
    virtual ~Finger();
    virtual bool init();
    int round(float number);
};

#endif /* defined(__ATM_Killer__Finger__) */
